package com.example.xdzx.utils;

import com.example.xdzx.pojo.LostItems;

import java.util.Comparator;

public class ItemsComparator implements Comparator<LostItems> {
    @Override
    public int compare(LostItems o1, LostItems o2) {
        if(o1.getCreateTime().getTime() < o2.getCreateTime().getTime()){
            return -1;
        }else if(o1.getCreateTime().getTime() == o2.getCreateTime().getTime()){
            return 0;
        }else{
            return 1;
        }
    }
}
